import React from 'react'
import { Redirect } from 'react-router-dom'
import Root from 'pages/Root'
import G6Record from 'pages/G6Record'
import G5Record from 'pages/G5Record'
import Configuration from 'pages/Configuration'
import Prompt from 'pages/Prompt'
import VehicleList from 'pages/VehicleList'

export default [
  {
    path: '/',
    exact: true,
    component: () => <Redirect to="/g6Record"></Redirect>,
  },
  {
    component: Root,
    routes: [
      {
        path: '/g6Record',
        component: G6Record,
      },
      {
        path: '/g5Record',
        component: G5Record,
      },
      // 平台信息
      {
        path: '/configuration',
        component: Configuration,
      },
      // 芯片信息
      {
        path: '/prompt',
        component: Prompt,
      },
      {
        path: '/vehicleList',
        component: VehicleList,
      },
    ],
  },
]
